import {defineConfig} from 'vite'
import components from 'unplugin-vue-components/vite'
import {VarletUIResolver} from 'unplugin-vue-components/resolvers'
import styleImport, {VantResolve} from 'vite-plugin-style-import';
import vue from '@vitejs/plugin-vue'
import {resolve} from "path";

// https://vitejs.dev/config/
export default defineConfig({
    plugins: [
        vue(),
        components({
            resolvers: [VarletUIResolver()]
        }),
        styleImport({
            resolves: [VantResolve()],
        })
    ],
    resolve: {
        alias: {
            '@': resolve(__dirname, './src')
        }
    }
})
